{template header}
<style type="text/css">
    table td:nth-child(4) img,
    table td:nth-child(5) img { outline: none; border: none; }
</style>
<div class="bs-docs-example" style="clear:both;">
    <a class="btn btn-primary" href="?c=admin&a=medalInfo">新建</a>
    <table class="table table-striped">
        <thead>
            <tr>
                <th>ID</th>
                <th>勋章名</th>
                <th>勋章图片</th>
                <th>所属分类</th>
                <th>里程要求</th>
                <th>针对人群</th>
                <th>开始日期</th>
                <th>结束日期</th>
                <th>操作</th>
            </tr>
        </thead>
        <tbody>
            {loop $medalList $k $v}
            <tr>
                <td>{$v['medal_id']}</td>
                <td>{$v['medal_name']}</td>
                <td><img width="100" src="{$v['img1']}" /></td>
                <td>{eval echo $medalCate[$v['cate']]}</td>
                <td>{$v['mileage_limit']}</td>
                <td>{if $v['gender']==0}所有{elseif $v['gender']==1}男{else}女{/if}</td>
                <td>{eval echo date('Y-m-d H:i:s', $v['start_time'])}</td>
                <td>{eval echo date('Y-m-d H:i:s', $v['end_time'])}</td>
                <td>
                    <a class="btn btn-default" href="?c=admin&a=medalInfo&medal_id={$v['medal_id']}">编辑</a>
                    <a class="btn btn-default" href="?c=admin&a=dealMedal&medal_id={$v['medal_id']}">发放</a>
                </td>
            </tr>
            {/loop}
        </tbody>
    </table>
</div>
<div class="pagination">
    <ul>
        {$pageStr}
    </ul>
</div>
{template footer}
